﻿using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace OrBitDataModule.CustomEventHandler
{
    public class ProcessedFileSystemEventArgs : EventArgs
    {
        /// <summary>
        /// 是否已提交，如果为false，平台负责提交，为true就跳过提交，需要在脚本中自行处理
        /// </summary>
        public bool IsSubmit { get; set; } = true;
        /// <summary>
        /// 是否移动文件到备份目录
        /// </summary>
        public bool IsMoveToBackupDirectory { get; set; } = true;
        /// <summary>
        /// 文本内容
        /// </summary>
        public string Content { get; set; }


        /// <summary>
        /// 文件改变类型
        /// </summary>
        public WatcherChangeTypes ChangeType { get; }


        /// <summary>
        /// 完整路径
        /// </summary>
        public string FullPath { get; }

        /// <summary>
        /// 文件名
        /// </summary>
        public string Name { get; }
        public ProcessedFileSystemEventArgs(WatcherChangeTypes changeType, string fullPath, string name)
        {
            this.ChangeType = changeType;
            this.Name = name;
            this.FullPath = fullPath;
        }
    }
}
